Skip to main content

Greedy Algorithms

  • Greedy algorithms optimize locally, hoping to end up with a global optimum.
  • Greedy algorithms are easy to write and fast to run, so they make good approximation algorithms.
  • NP-complete
    • NP-complete problems have no known fast solution.
    • If you have an NP-complete problem, your best bet is to use an approximation algorithm.